GtkDialog: Connect to activate signals only once
authorTimm Bäder <mail@baedert.org>
Sun, 16 Nov 2014 09:29:15 +0000 (10:29 +0100)
committerTimm Bäder <mail@baedert.org>
Mon, 17 Nov 2014 17:37:47 +0000 (18:37 +0100)
If the widget is an action widget, it's been previously added with
gtk_dialog_add_action_widget, which calls add_response_data on it, which
in turn connects to the clicked/activate signal of that widget, so we
don't need to connect to that signal a second time in
gtk_buildable_custom_finished.

gtk/gtkdialog.c

index b1ae4c215c94869b829f5ba5e42c80f65a5c40a1..b02c6048c1caaf37b6a3d9c75e9111f2645df5fc 100644 (file)
@@ -1840,7 +1840,7 @@ gtk_dialog_buildable_custom_finished (GtkBuildable *buildable,
       else
        signal_id = GTK_WIDGET_GET_CLASS (object)->activate_signal;
 
-      if (signal_id)
+      if (signal_id && !is_action)
        {
          GClosure *closure;